﻿using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DrawAGraph
{
    internal class ShapeFactory
    {
        public static Shape CreateShape(string shapeType, Color color)
        {
            switch (shapeType)
            {
                case "Circle":
                    return new Circle(color);
                case "Rectangle":
                    return new Rectangle(color);
                case "Triangle":
                    return new Triangle(color);
                case "Ellipse":
                    return new Ellipse(color);
                default:
                    return null;
            }
        }
    }
}
